<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <title>Title</title>
  </head>
  <body></body>
  <script>
    let hd = {};
    // 添加属性
    hd.name = "houdunren";
    hd["age"] = 22;

    console.log(hd);
    //删除属性
    delete hd.age;

    // 判断对象自身是否含有某个属性
    if (hd.hasOwnProperty("name")) {
      console.log("确实含有name");
    }
  </script>
</html>
